package me.a02demo2;

public class Test3 {
    public static void main(String[] args) {
        for (int i = 100; i < 1000; i++) {
            if (isShui(i)) {
                System.out.println(i);
            }
        }
    }

    public static boolean isShui(int num) {
        int ge = num % 10;
        int shi = num / 10 % 10;
        int bai = num / 100 % 10;
        double sum = Math.pow(ge, 3) + Math.pow(shi, 3) + Math.pow(bai, 3);
        return sum == num;
    }
}
